package com.cloud.model;

import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author jaddy0302 Rivulet TableProperties.java 2010-3-22
 * 
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Document
public class TableProperties implements java.io.Serializable, Cloneable {
	private static final long serialVersionUID = 3601436061896426576L;

	@Id
	private String id;
	private String tablename;
	private String dbtableid;
	private String name;
	private String code;
	private String fieldname;
	private int datatypecode; // 变更用处，修改为字段长度
	private String datatypename;
	private String indexdatatype;
	private String groupid;
	private String userid;
	private Boolean pk = false;
	private Boolean modits = false;
	private String orgi;
	private String viewtype;
	private int sortindex = 1;
	private boolean token;
	private String tokentype; // 分词方式
	private boolean inx = true;
	private boolean title = false;
	private boolean systemfield = false; // 变更用处，是否流程变量
	private int length = 255;
	private boolean fieldstatus;
	private boolean seldata;
	private String seldatatype; // 选择数据方式 ： 字典数据 ， 表数据 ， 如果是表数据，则需要选择 表ID
	private String seldatacode;
	private String seldatakey;
	private String seldatavalue;
	private String reftbid;
	private String reftbname;
	private String reftpid;
	private String reftpname;
	private String reftype;
	private String reftptitlefield;
	private boolean defaultsort; // 是否默认排序字段
	private boolean descorder; // 默认倒叙排列
	private String defaultvalue;
	private String defaultvaluetitle;
	private String defaultfieldvalue;
	private boolean multpartfile = true;
	private String uploadtype;
	private String cascadetype;// 级联删除 none不删除，deleteself删除主数据，deleteall删除关联数据
	private boolean impfield = false;

	private boolean reffk = false; // 是否外键关联
}
